package com.hxl.tech.gateway.auth.model;

import lombok.Data;
import javax.persistence.Embeddable;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 开放接口授权 Model
 * @author soliddq
 * @date 2023-10-10
 */
@Entity
@Data
public class OpenApiApproval implements Serializable {

    @EmbeddedId
    private Id id;

    private String createBy;

    private LocalDateTime createTime;

    @Embeddable
    @Data
    public static class Id implements Serializable {
        private String appId;
        private String apiName;

        public Id() {
        }

        public Id(String appId,String apiName) {
            this.appId = appId;
            this.apiName = apiName;
        }
    }

}
